package com.huaweicloud.sdk.workspaceapp.v1.model;

import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonProperty;

import java.util.Objects;

/**
 * FileRedirectionBandwidthPercentageOptions
 */
public class FileRedirectionBandwidthPercentageOptions {

    @JsonInclude(JsonInclude.Include.NON_NULL)
    @JsonProperty(value = "file_redirection_bandwidth_percentage_value")

    private Integer fileRedirectionBandwidthPercentageValue;

    public FileRedirectionBandwidthPercentageOptions withFileRedirectionBandwidthPercentageValue(
        Integer fileRedirectionBandwidthPercentageValue) {
        this.fileRedirectionBandwidthPercentageValue = fileRedirectionBandwidthPercentageValue;
        return this;
    }

    /**
     * 文件重定向带宽百分比控制量（%）。取值范围为[0-100]。默认：30。
     * minimum: 0
     * maximum: 100
     * @return fileRedirectionBandwidthPercentageValue
     */
    public Integer getFileRedirectionBandwidthPercentageValue() {
        return fileRedirectionBandwidthPercentageValue;
    }

    public void setFileRedirectionBandwidthPercentageValue(Integer fileRedirectionBandwidthPercentageValue) {
        this.fileRedirectionBandwidthPercentageValue = fileRedirectionBandwidthPercentageValue;
    }

    @Override
    public boolean equals(java.lang.Object obj) {
        if (this == obj) {
            return true;
        }
        if (obj == null || getClass() != obj.getClass()) {
            return false;
        }
        FileRedirectionBandwidthPercentageOptions that = (FileRedirectionBandwidthPercentageOptions) obj;
        return Objects.equals(this.fileRedirectionBandwidthPercentageValue,
            that.fileRedirectionBandwidthPercentageValue);
    }

    @Override
    public int hashCode() {
        return Objects.hash(fileRedirectionBandwidthPercentageValue);
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append("class FileRedirectionBandwidthPercentageOptions {\n");
        sb.append("    fileRedirectionBandwidthPercentageValue: ")
            .append(toIndentedString(fileRedirectionBandwidthPercentageValue))
            .append("\n");
        sb.append("}");
        return sb.toString();
    }

    /**
     * Convert the given object to string with each line indented by 4 spaces
     * (except the first line).
     */
    private String toIndentedString(java.lang.Object o) {
        if (o == null) {
            return "null";
        }
        return o.toString().replace("\n", "\n    ");
    }

}
